﻿using System;
using SharpSqlAnalyzer.nodes;

namespace SharpSqlAnalyzer.stmt.db2
{
	// Token: 0x020001DF RID: 479
	public class TDb2LoopStmt : TBlockSqlStatement
	{
		// Token: 0x06001028 RID: 4136 RVA: 0x0030CA60 File Offset: 0x0030AC60
		public TDb2LoopStmt(EDbVendor dbvendor) : base(dbvendor)
		{
			this.sqlstatementtype = ESqlStatementType.sstdb2loopstmt;
		}

		// Token: 0x06001029 RID: 4137 RVA: 0x0030CA74 File Offset: 0x0030AC74
		internal override void buildsql()
		{
		}

		// Token: 0x0600102A RID: 4138 RVA: 0x0030CA76 File Offset: 0x0030AC76
		internal override void clear()
		{
		}

		// Token: 0x0600102B RID: 4139 RVA: 0x0030CA78 File Offset: 0x0030AC78
		internal override string getasprettytext()
		{
			return "";
		}

		// Token: 0x0600102C RID: 4140 RVA: 0x0030CA7F File Offset: 0x0030AC7F
		internal virtual void iterate(TVisitorAbs pvisitor)
		{
		}

		// Token: 0x0600102D RID: 4141 RVA: 0x0030CA84 File Offset: 0x0030AC84
		public override int doParseStatement(TCustomSqlStatement psql)
		{
			if (this.rootNode == null)
			{
				return -1;
			}
			TLoopSqlNode tloopSqlNode = (TLoopSqlNode)this.rootNode;
			base.doParseStatement(psql);
			tloopSqlNode.Stmts.doParse(this, ESqlClause.unknown);
			for (int i = 0; i < tloopSqlNode.Stmts.size(); i++)
			{
				this.BodyStatements.add(tloopSqlNode.Stmts.getStatementSqlNode(i).Stmt);
			}
			return 0;
		}

		// Token: 0x0600102E RID: 4142 RVA: 0x0030CAEF File Offset: 0x0030ACEF
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			this.BodyStatements.accept(v);
			v.postVisit(this);
		}
	}
}
